import { defineConfig } from 'vite';
import path from 'path'
export default defineConfig({
  build: {
    minify: true,
    lib: {
      entry: path.resolve(__dirname, './src/packages/styles/index.less'),
      formats: ['es'],
      name: 'style',
      fileName: 'style'
    },
    rollupOptions: {
      // 确保外部化处理那些你不想打包进库的依赖
      external: ['vue'],
      output: {
        dir: path.resolve(__dirname, './dist/packages/styles')
      }
    },
    emptyOutDir: false
  }
});
